const a = async function (
  event,
  { $grid },
  { params = {}, memory, origin },
  { dc: { open, setModal }, xe: { get } }
) {
  const ret = await new Promise((resolve) => {
    const transfer = params;
    const layout = { id: "1785946370247495682" };
    const modal = {
      title: "添加项目",
      width: "55vw",
      height: document.body.clientHeight * 0.45,
      defaultFullscreen: false,
      destroyOnClose: false,
      maskClosable: false,
      open: true,
      showOkBtn: false,
      showCancelBtn: true,
      afterClose: function () {
        const ret = get(memory, "modal", false);
        delete memory.modal;
        resolve(ret);
      },
    };
    const inner = {};
    console.log("inner click: ", $grid, origin, memory, params, {
      inner,
      layout,
      modal,
      transfer,
    });
    open({ inner, layout, modal, transfer });
  });
  console.log("modal ret: ", ret);
  if (!ret) return;
  $grid.commitProxy("query");
};
